package com.cqjtu.eecs.service.impl;

import com.cqjtu.eecs.entity.NaturalClass;
import com.cqjtu.eecs.mapper.NaturalClassMapper;
import com.cqjtu.eecs.service.INaturalClassService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * <p>
 * 自然班 服务实现类
 * </p>
 *
 * @author    
 * @since 2022-03-07
 */
@Service
public class NaturalClassServiceImpl extends ServiceImpl<NaturalClassMapper, NaturalClass> implements INaturalClassService {

    @Resource
    private NaturalClassMapper naturalClassMapper;
    @Override
    public List<NaturalClass> selectAllNaturalClass() {
        return naturalClassMapper.selectAllNaturalClass();
    }

    @Override
    public List<NaturalClass> selectAllNaturalClassLimit(Integer currPage, Integer pageSize) {
        return naturalClassMapper.selectAllNaturalClassLimit(currPage,pageSize);
    }

    @Override
    public List<NaturalClass> selectAllNaturalClassByGrade(Integer grade, Integer currPage, Integer pageSize) {
        return naturalClassMapper.selectAllNaturalClassByGrade(grade,currPage,pageSize);
    }

    @Override
    public List<NaturalClass> selectAllNaturalClassByGradeAndmajorName(Integer grade, String majorCode, Integer currPage, Integer pageSize) {
        return naturalClassMapper.selectAllNaturalClassByGradeAndmajorName(grade, majorCode, currPage, pageSize);
    }
}
